#include<iostream>
#include<vector>
using namespace std;
class Solution{
	public:
		vector<int>twoSum(vector<int>& nums,int target){
			vector<int>result(2);
			for(int i=0;i<nums.size()-1;i++){
				for(int j=i+1;j<nums.size();j++){
					if((nums[i]+nums[j])==target){
						result[0]=i;
						result[1]=j;
						return result;
					}
				}
			}
			return result;
		}
};
int main(){
	vector<int>nums{2,4,3,5,7,2};
	int target=6;
	Solution s;
	vector<int>result=s.twoSum(nums,target);
	for(int i=0;i<2;i++){
		cout<<result[i]<<endl;
	}
}
